
/**监听状态 */
export class WatchStatus {
  private status = 1;

  /**不监听 */
  noWatch() {
    this.status = 0;
  }

  /**监听 */
  watch() {
    this.status = 1;
  }

  /** 是否是监听 */
  isWatch() {
    let result = this.status == 1 ? true : false;
    if (!result)
      this.status = 1;
    return result;
  }
}